FreeCntr
 
 
 Bean FreeCntr
 
Free running counter

Typical usage of the bean in user's code.

Typical Usage:

Required bean name is "FC1".

(1)
It's not reasonable to use the bean for time measurement without any methods. There is some code snippet which measures the time of the for-cycle in counter ticks in the following example.

 MAIN.C

void main(void)
{
  unsigned char i;
  word time;
  
  FC1_Reset(); /* reset the counter */
  for( i=0; i<255; ++i ); /* for-cycle */
  
  /* get measured time of whole for-cycle */
  time = FC1_GetCounterValue(); 
}

For more about typical usage of the bean code please refer to the page Bean Code Typical Usage.


Processor ExpertTM and Embedded BeansTM are registered trademarks of UNIS, Ltd.
©1997-2005, UNIS, Ltd.